<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
<script src="js/jquery-2.1.1.min.js"></script>
<script src="js/loading.js"></script>
<script src="js/jquery.cookie.js"></script>
<script src="js/commonTool.js"></script>
<script type="text/javascript" src="js/jquery.cookie.js"></script>
<link rel="stylesheet" href="css/style.css">
<link rel="stylesheet" href="css/mainstyle.css">
<style>
#cont_title{
            position: relative;
            width: 100%;
            height: 40px;
            background-color: dodgerblue;
            color: white;
            
        }
        .tit{
            position: absolute;
            height: 20px;
            width: 100px;
            top: 50%;
            left: 10px;
            margin-top: -10px;
        } 
     .custom_table{
            width: 100%;
            text-align: center;
            vertical-align: middle;
            border-color: lightgray;
            font-size: 13px;
            position: absolute;
        }
        
        .custom_table tr{
            height: 30px;
        }
</style>
<script>
$(function(){
    $("#header").load("header.html");
    var data=localStorage.keydata;
    var title=$.cookie('keyname');
    $(".tit").text(title);
    var detail=JSON.parse(data);
    $("#scan_tb").children().each(function(){
                       $(this).remove(); 
                    });
              
              var html = '';
              $.each(detail, function (key, value) {
                    html += '<tr>'+
                    '<td>'+value.title+'</td>' +
                    '<td>'+value.pv+'</td>' +
                    '<td>'+value.average_pv+'</td>' +
                    '<td>'+value.ip+'</td>' +
                    '<td>'+value.uv+'</td>' +
                    '</tr>';
                });
              $("#scan_tb").append(html);   
});
</script>
<title>详细来源</title>
</head>
<body>
<div id="header"></div>
<div id="content">
<div id="cont_title"><span class="tit">详细来源</span></div>
 <table id="scanTable" class="custom_table"  border="1" cellspacing="0">
                            <thead>
                            <tr>
			                 <th scope="col">来源</th>
			                 <th scope="col">浏览量</th>
			                 <th scope="col">人均浏览</th>
			                 <th scope="col">IP</th>
			                 <th scope="col">独立访客</th>
			                 </tr>
                           </thead>
                            <tbody id="scan_tb" valign="middle">
                            </tbody>
                        </table>	

</div>
</body>
</html>